<?php
require_once 'classes/Database.php';
require_once 'classes/OrderManager.php';

$orderManager = new OrderManager();
$stats = $orderManager->getOrderStatistics();
echo "订单统计:\n";
print_r($stats);

$orders = $orderManager->getAllOrders();
echo "\n所有订单:\n";
foreach ($orders as $order) {
    echo "订单号: {$order['order_no']}, 状态: {$order['status']}, 金额: {$order['total_amount']}, CDK码: {$order['cdk_code']}\n";
}
?>
